from django.db import models

# Create your models here.
#  机柜
class Cabinet(models.Model):
    name = models.CharField(max_length=40)
    code = models.CharField(max_length=16)
    count = models.IntegerField()

    def __str__(self):
       """将模型类以字符串的方式输出"""
       return self.name


# 服务器
class Server(models.Model):
    name = models.CharField(max_length=40)

    def __str__(self):
       """将模型类以字符串的方式输出"""
       return self.name

       